Skip to main content

Full text of "Arduino"

See other formats


Control a Servo with a Force-Sensitive Resistor 



.1 



Make Projects 



build, hack, tweak, share, discover^ 



Control a Servo with a Force- 
Sensitive Resistor 

Written By: Eric Weinhoffer 

SUMMARY 

All required parts are included in the Maker Shed's Ultimate Microcontroller Pack . 



© Make Projects www.makeprojects.com Page 1 of 3 



Control a Servo with a Force-Sensitive Resistor 



Step 1 — Control a Servo with a Force-Sensitive Resistor 




• Start with the ground and power rails - use two jumpers to provide 5V to one rail 
(preferably the red one) and GND to the other. 

• Now add the force-sensitive resistor (FSR) to the breadboard (E15 and E16). Polarity 
doesn't matter here, so any orientation will work. 

• A 10kQ pulldown resistor is needed to control current flow to the sensor. Wire it up 
between one side of the FSR (C16) and the GND rail on the breadboard. 

Step 2 




• To provide power to the FSR, use a jumper wire to connect the side we haven't wired up 
yet (A15) to the 5V rail on the breadboard. 

• Next, use a longer jumper wire to connect the FSR to the Arduino. In this case, analog pin 
AO gets connected to the row with the 10kQ resistor and GND jumper (D16). 



© Make Projects 



www.makeprojects.com 



Page 2 of 3 



Control a Servo with a Force-Sensitive Resistor 



Step 3 




• Now to connect the servo. Use three jumper wires to go between the servo's female 
connectors and the breadboard. Try to match up the colors as best you can, to minimize 
confusion. 

• Hook up the PWR (red wire on the servo) to the 5V rail on the breadboard, GND (probably 
the brown wire on the servo) to the GND rail on the breadboard, and the signal wire 
(orange, in this case) to Digital Pin 9 on the Arduino. 

• Head over to GitHub to download the code (or copy-paste it right into the Arduino IDE), 
and experiment! 

This document was last generated on 2013-02-01 06:10:55 PM. 



© Make Projects 



www.makeprojects.com 



Page 3 of 3